gtk4.git
10 years agotooltip: Use an element name
Matthias Clasen [Tue, 27 Oct 2015 19:10:39 +0000 (15:10 -0400)]
tooltip: Use an element name

This will allow us to drop hardcoded type names in the theme.

10 years agomir: emulate pointer for all touch events
William Hua [Tue, 27 Oct 2015 20:19:42 +0000 (16:19 -0400)]
mir: emulate pointer for all touch events

10 years agocssselector: Print name and any selector first
Benjamin Otte [Tue, 27 Oct 2015 19:11:08 +0000 (20:11 +0100)]
cssselector: Print name and any selector first

When printing a "compound selector", make sure the name and universal
selectors are printed at the beginning and class, id, etc. selectors are
printed last.

10 years agoAdwaita: Update GtkAssistant theming
Matthias Clasen [Tue, 27 Oct 2015 18:37:04 +0000 (14:37 -0400)]
Adwaita: Update GtkAssistant theming

Use the new element name, instead of hardcoding the type.

10 years agoassistant: Use an element name
Matthias Clasen [Tue, 27 Oct 2015 18:31:32 +0000 (14:31 -0400)]
assistant: Use an element name

This will allow us to drop hardcoded type names in the theme.

10 years agoFix make check
Matthias Clasen [Tue, 27 Oct 2015 17:26:50 +0000 (13:26 -0400)]
Fix make check

Don't try setting GtkShortcutsShortcut::accelerator to a
random value, it only accepts strings that it can parse.

10 years agotoolitemgroup: Fix the previous change
Matthias Clasen [Tue, 27 Oct 2015 16:53:43 +0000 (12:53 -0400)]
toolitemgroup: Fix the previous change

dispose can be called more than once.

10 years agotool item group: Don't leak a button
Matthias Clasen [Tue, 27 Oct 2015 15:07:53 +0000 (11:07 -0400)]
tool item group: Don't leak a button

This causes a hickup in the new css node machinery, causing
the default-value test to fail.

10 years agoicon theme: Ensure to propagate an error
Matthias Clasen [Tue, 27 Oct 2015 15:05:00 +0000 (11:05 -0400)]
icon theme: Ensure to propagate an error

If the svg pixbuf loader is not available, we end up with criticals
from gtk_css_image_icon_theme_draw because gtk_icon_info_load_symbolic
returns NULL without setting an error.

Avoid this by propagating the load error.

10 years agomir: warning clean-up
William Hua [Tue, 27 Oct 2015 14:50:18 +0000 (10:50 -0400)]
mir: warning clean-up

10 years agomir: allow logging touch events
William Hua [Tue, 27 Oct 2015 14:09:34 +0000 (10:09 -0400)]
mir: allow logging touch events

10 years agoshortcuts: Some property hygiene
Matthias Clasen [Tue, 27 Oct 2015 12:48:08 +0000 (08:48 -0400)]
shortcuts: Some property hygiene

Bring property notification for some of the new shortcuts widgets
up to the standards of our testsuite.

10 years agogdkpixbuf-drawable: reinstate accidentally removed line
Lars Uebernickel [Tue, 27 Oct 2015 12:38:14 +0000 (13:38 +0100)]
gdkpixbuf-drawable: reinstate accidentally removed line

10 years agogdk_pixbuf_get_from_window: honor device scale
Lars Uebernickel [Mon, 26 Oct 2015 09:12:34 +0000 (10:12 +0100)]
gdk_pixbuf_get_from_window: honor device scale

gdk_pixbuf_get_from_window() paints the given window onto a new cairo
surface. Create that new surface with the same device scale as the
window so that the result is not scaled down on hidpi screens.

https://bugzilla.gnome.org/show_bug.cgi?id=757147

10 years agoUpdated Czech translation
Marek Černocký [Tue, 27 Oct 2015 06:38:21 +0000 (07:38 +0100)]
Updated Czech translation

10 years agoinspector: Allow editing css node properties
Matthias Clasen [Tue, 27 Oct 2015 03:37:13 +0000 (23:37 -0400)]
inspector: Allow editing css node properties

This reuses the property editor infrastructure from the
property list pages. Good that css nodes are objects.

10 years agoinspector: Support editing interned string properties
Matthias Clasen [Tue, 27 Oct 2015 03:38:05 +0000 (23:38 -0400)]
inspector: Support editing interned string properties

Sadly, interned string properties cannot be handled generically
at all - GObject insists on inserting a strcpy in any attempt
to set a string property with generic api, destroying the
internedness of the string.

Therefore, we have to special-case GtkCssNode in the property
editor code :-(

10 years agoAdd some api annotations
Matthias Clasen [Tue, 27 Oct 2015 03:35:22 +0000 (23:35 -0400)]
Add some api annotations

Nothing is using the /*interned*/ annotations currently,
but if we are doing this, we should be consistent.

10 years agowidget: Add name to widget paths
Benjamin Otte [Tue, 27 Oct 2015 02:11:56 +0000 (03:11 +0100)]
widget: Add name to widget paths

This changes widget paths for widgets with a CSS name to return that CSS
name, now that we have added API for it.
This means that style properties are now matches using the CSS name.

Also fix the theme to use the correct name when matching style properties.

10 years agocssmatcher: Actually match names for widget paths
Benjamin Otte [Tue, 27 Oct 2015 02:11:21 +0000 (03:11 +0100)]
cssmatcher: Actually match names for widget paths

The type is always 0 when we use names. So this would always return
FALSE. Oops.

10 years agoentry: properly update css subnode state
Matthias Clasen [Tue, 27 Oct 2015 02:08:03 +0000 (22:08 -0400)]
entry: properly update css subnode state

Update the state of the css subnodes for icons when
appropriate, and avoid calling set_state after save_to_node.

10 years agoentry: Use better element name for progress
Matthias Clasen [Tue, 27 Oct 2015 01:32:26 +0000 (21:32 -0400)]
entry: Use better element name for progress

Change the name of the CSS subnode for progress rendering from
progressbar to progress. This will align better with GtkProgressBar.

10 years agogdk: Deprecate gdk_display_get_screen
Robert Ancell [Thu, 22 Oct 2015 03:45:48 +0000 (16:45 +1300)]
gdk: Deprecate gdk_display_get_screen

10 years agowayland: Don't use GTK symbols from GDK
Jonas Ådahl [Tue, 27 Oct 2015 01:00:48 +0000 (09:00 +0800)]
wayland: Don't use GTK symbols from GDK

GTK_WINDOW_POPUP sets the GdkWindow type to GDK_WINDOW_TEMP, so use
that in GDK, not the GTK symbol which doesn't exist there.

10 years agoAPI: Add gtk_widget_path_iter_set_object_name()
Benjamin Otte [Tue, 27 Oct 2015 00:26:20 +0000 (01:26 +0100)]
API: Add gtk_widget_path_iter_set_object_name()

... and gtk_widget_path_iter_get_object_name(). This allows applications
that still use widget paths to use the new object names to get the
correct styling.

Mutter and webkit-gtk are examples here.

10 years agoGtkTreeView: Rework the search window hack so it also works on Wayland
Jonas Ådahl [Sun, 18 Oct 2015 13:23:12 +0000 (21:23 +0800)]
GtkTreeView: Rework the search window hack so it also works on Wayland

The search window of a tree view was implemented by showing without
making it visible by by positioning it outside the screen edge. This is
not possible on Wayland, so implement another method for being able to
enter text into a non-visible entry.

The new method is implemented by, before showing the window, pass the
key event directly to the IM context backing the entry. If the key
event triggered the context to commit new text or change the preedit
content, the search window is shown, and from that point the key events
are forwarded directly to the entry widget.

https://bugzilla.gnome.org/show_bug.cgi?id=756780

10 years agowayland: Map UTILITY hinted popup windows as subsurfaces
Jonas Ådahl [Sun, 18 Oct 2015 13:21:51 +0000 (21:21 +0800)]
wayland: Map UTILITY hinted popup windows as subsurfaces

Currently used by GtkTreeView to map windows without changing focus. We
can't map this as a popup, because popup implies focus change.

https://bugzilla.gnome.org/show_bug.cgi?id=756780

10 years agoGtkTreeView: Make a search window destroy helper
Jonas Ådahl [Sun, 18 Oct 2015 13:12:59 +0000 (21:12 +0800)]
GtkTreeView: Make a search window destroy helper

https://bugzilla.gnome.org/show_bug.cgi?id=756780

10 years agowayland: Don't try to use subsurfaces as popup parents
Jonas Ådahl [Sun, 18 Oct 2015 13:03:52 +0000 (21:03 +0800)]
wayland: Don't try to use subsurfaces as popup parents

If a GtkMenu (or something else that is mapped as a xdg_popup) tries to
use a subsurface window as a parent, it will be terminated by the
compositor due to protocol violation. So to avoid this, if a parent
window is not a xdg_popup or xdg_surface, i.e. a wl_subsurface, then
traverse up the transient parents until we find the right popup parent.

https://bugzilla.gnome.org/show_bug.cgi?id=756780

10 years agowayland: Make window type conditions switches
Jonas Ådahl [Sun, 18 Oct 2015 12:23:07 +0000 (20:23 +0800)]
wayland: Make window type conditions switches

In order to make it easier to add/remove in future commits.

https://bugzilla.gnome.org/show_bug.cgi?id=756780

10 years agoGtkTreeView: Use more consistent search window naming
Jonas Ådahl [Sat, 17 Oct 2015 11:25:52 +0000 (19:25 +0800)]
GtkTreeView: Use more consistent search window naming

Instead of alternating between search dialog and search window, use
search window everywhere.

https://bugzilla.gnome.org/show_bug.cgi?id=756780

10 years agoentry: Bring back icon padding
Matthias Clasen [Mon, 26 Oct 2015 20:51:28 +0000 (16:51 -0400)]
entry: Bring back icon padding

Not sure why this is necessary now, but it is.

10 years agoentry: Only set one of the .left, .right style classes
Matthias Clasen [Mon, 26 Oct 2015 19:28:50 +0000 (15:28 -0400)]
entry: Only set one of the .left, .right style classes

We were not removing the old style class when adding a new one.

10 years agotestassistant: Add another example
Matthias Clasen [Mon, 26 Oct 2015 13:16:38 +0000 (09:16 -0400)]
testassistant: Add another example

This adds a test involving removing and re-adding pages, to
help with
https://bugzilla.gnome.org/show_bug.cgi?id=756385

10 years agoassistant: Handle page-type and title changes properly
Matthias Clasen [Mon, 26 Oct 2015 13:01:07 +0000 (09:01 -0400)]
assistant: Handle page-type and title changes properly

We need to update our state when a pages' type or title changes.

10 years agoshortcuts: Cosmetic change
Matthias Clasen [Mon, 26 Oct 2015 11:22:28 +0000 (07:22 -0400)]
shortcuts: Cosmetic change

The .flat style class is controlled by the relief property,
so just use that instead of manually setting style classes.

10 years agolabel docs: Mention common style classes
Matthias Clasen [Sun, 25 Oct 2015 22:53:56 +0000 (18:53 -0400)]
label docs: Mention common style classes

Mention some of the style classes that are commonly used
with labels.

10 years agoGtkWindow: fix move/get position with CSD
Olivier Fourdan [Thu, 22 Oct 2015 12:19:15 +0000 (14:19 +0200)]
GtkWindow: fix move/get position with CSD

Take into account and compensate for the size of the client side
decorations widgets in gtk_window_move() and gtk_window_get_pos()
including gravity.

Bugzilla: https://bugzilla.gnome.org/show_bug.cgi?id=756618

10 years agoGtkWindow: add up CSD size in gtk_window_resize()
Olivier Fourdan [Thu, 15 Oct 2015 09:25:51 +0000 (11:25 +0200)]
GtkWindow: add up CSD size in gtk_window_resize()

When client side decoration is used, the size passed to
gtk_window_resize() or retrieved from gtk_window_get_size() for top-
level windows also accounts for the client side decorations widgets
such as the title bar or the shadow borders.

Add up the size of these additional controls to the given size to get
the size expected.

Bugzilla: https://bugzilla.gnome.org/show_bug.cgi?id=756618

10 years agoUpdated Czech translation
Marek Černocký [Mon, 26 Oct 2015 06:56:07 +0000 (07:56 +0100)]
Updated Czech translation

10 years agoHighContrast: Don't use GtkInfoBar type name
Matthias Clasen [Sun, 25 Oct 2015 21:19:34 +0000 (17:19 -0400)]
HighContrast: Don't use GtkInfoBar type name

We have a proper element name for it now.

10 years agoAdwaita: Don't use GtkInfoBar type name
Matthias Clasen [Sun, 25 Oct 2015 21:19:01 +0000 (17:19 -0400)]
Adwaita: Don't use GtkInfoBar type name

We have a proper element name for it now.

10 years agoinfobar: Add a name to the css node
Matthias Clasen [Sun, 25 Oct 2015 21:18:20 +0000 (17:18 -0400)]
infobar: Add a name to the css node

This lets us avoid the type name in css.

10 years agoHighContrast: Update separator rendering
Matthias Clasen [Sun, 25 Oct 2015 20:29:11 +0000 (16:29 -0400)]
HighContrast: Update separator rendering

Adapt HighContrast t othe changes in the pre-previous commit.

10 years agoAdwaita: Update separator styling
Matthias Clasen [Sun, 25 Oct 2015 20:28:38 +0000 (16:28 -0400)]
Adwaita: Update separator styling

Adapt Adwaita to the changes in the previous commit.

10 years agoseparator: Use the element name separator
Matthias Clasen [Sun, 25 Oct 2015 20:27:44 +0000 (16:27 -0400)]
separator: Use the element name separator

Switch GtkSeparator from using the .separator style class to
using the element name separator for its css node.

10 years agoAdwaita: Update accel label styling
Matthias Clasen [Sun, 25 Oct 2015 19:43:41 +0000 (15:43 -0400)]
Adwaita: Update accel label styling

Adapt Adwaita to the changes in the previous commit.

10 years agoaccel label: Use a css node for the accelerator
Matthias Clasen [Sun, 25 Oct 2015 19:42:40 +0000 (15:42 -0400)]
accel label: Use a css node for the accelerator

Use a permanent subnode with name accelerator instead of the
.accelerator style class.

10 years agoHighContrast: Update spinner rendering
Matthias Clasen [Sun, 25 Oct 2015 19:21:52 +0000 (15:21 -0400)]
HighContrast: Update spinner rendering

Adapt HighContrast to the changes in the pre-previous commit.

10 years agoAdwaita: Update spinner styling
Matthias Clasen [Sun, 25 Oct 2015 19:21:17 +0000 (15:21 -0400)]
Adwaita: Update spinner styling

Adapt Adwaita to the changes in the previous commit.

10 years agospinner: Use the element name spinner
Matthias Clasen [Sun, 25 Oct 2015 19:20:23 +0000 (15:20 -0400)]
spinner: Use the element name spinner

Switch GtkSpinner from using the .spinner style class to
using the element name spinner for its css node.

10 years agodocs: Add index for 3.20 api
Rico Tzschichholz [Sun, 25 Oct 2015 18:35:33 +0000 (19:35 +0100)]
docs: Add index for 3.20 api

10 years agoTranslate GDK_KEY_KP_Decimal according to locale
Matthias Clasen [Tue, 20 Oct 2015 15:06:43 +0000 (11:06 -0400)]
Translate GDK_KEY_KP_Decimal according to locale

It makes sense that you should be able to type numbers that are
correctly formatted and parsable according to the current locale,
using just the keypad. This patch makes it so by translating
GDK_KEY_KP_Decimal to the decimal separator for the current locale,
instead of hardcoding a '.'.

https://bugzilla.gnome.org/show_bug.cgi?id=756751

10 years agoquartz: Don't use the instancetype keyword
Matthias Clasen [Sun, 25 Oct 2015 17:26:01 +0000 (13:26 -0400)]
quartz: Don't use the instancetype keyword

gdkcursor-quartz.c uses the instancetype keyword, which doesn't seem to
be supported in the version of Objective C that Snow Leopard uses.
Replacing that keyword with the thing it represents makes it build.

Patch by Ryan Hendrickson,
http://bugzilla.gnome.org/show_bug.cgi?id=756770

10 years agoinspector: Be more careful with dead objects
Matthias Clasen [Sun, 25 Oct 2015 17:11:17 +0000 (13:11 -0400)]
inspector: Be more careful with dead objects

gtk_inspector_object_tree_find_object accesses the type information
of the object, so we can't safely use it on an already decaying
object when we get a weak notify. Instead just walk the tree and
compare pointers, that is safe.

https://bugzilla.gnome.org/show_bug.cgi?id=756852

10 years agoinspector: Improve css node UI
Matthias Clasen [Sun, 25 Oct 2015 13:20:43 +0000 (09:20 -0400)]
inspector: Improve css node UI

All the other object pages have a title, this one was missing it.
Add one, so the page fits in with the rest.

10 years agoinspector: Allow editing strv-valued properties
Matthias Clasen [Sun, 25 Oct 2015 06:13:13 +0000 (02:13 -0400)]
inspector: Allow editing strv-valued properties

These do occur in some places, and we can easily allow editing
them.

10 years agoUpdated Czech translation
Marek Černocký [Sat, 24 Oct 2015 22:19:25 +0000 (00:19 +0200)]
Updated Czech translation

10 years agoFix the build
Matthias Clasen [Sat, 24 Oct 2015 21:04:38 +0000 (17:04 -0400)]
Fix the build

10 years agonotebook: Document css nodes and style class
Matthias Clasen [Sat, 24 Oct 2015 14:54:56 +0000 (10:54 -0400)]
notebook: Document css nodes and style class

This will have to be updates as we do further changes to the
way GtkNotebook does its rendering.

10 years agonotebook: Drop unneeded code
Matthias Clasen [Sat, 24 Oct 2015 14:32:35 +0000 (10:32 -0400)]
notebook: Drop unneeded code

We no longer need to set the position classes on the main css node,
since they are already set on the per-tab subnodes.

10 years agoHighContrast: Update notebook styling
Matthias Clasen [Sat, 24 Oct 2015 14:20:27 +0000 (10:20 -0400)]
HighContrast: Update notebook styling

The switch from .notebook to notebook requires minor changes,
such as moving the style properties into a separate selector.

10 years agoAdwaita: Update notebook styling
Matthias Clasen [Sat, 24 Oct 2015 14:17:31 +0000 (10:17 -0400)]
Adwaita: Update notebook styling

The switch from .notebook to notebook requires minor changes,
such as moving the style properties into a separate selector.

10 years agonotebook: Use the element name notebook
Matthias Clasen [Sat, 24 Oct 2015 14:10:33 +0000 (10:10 -0400)]
notebook: Use the element name notebook

Switch GtkNotebook from using the .notebook style class to
using the element name notebook for its main css node.

10 years agonotebook: Cosmetic cleanup
Matthias Clasen [Sat, 24 Oct 2015 14:11:17 +0000 (10:11 -0400)]
notebook: Cosmetic cleanup

10 years agoentry: Add css node documentation
Matthias Clasen [Fri, 23 Oct 2015 20:22:25 +0000 (16:22 -0400)]
entry: Add css node documentation

List the css names and the typical style classes that can be
expected to occur with entries.

10 years agoHighContrast: Update entry progress rendering
Matthias Clasen [Fri, 23 Oct 2015 20:16:55 +0000 (16:16 -0400)]
HighContrast: Update entry progress rendering

Adapt HighContrast to the changes in the pre-previous commit.

10 years agoAdwaita: Update entry progress rendering
Matthias Clasen [Fri, 23 Oct 2015 20:13:43 +0000 (16:13 -0400)]
Adwaita: Update entry progress rendering

Adapt Adwaita to the changes in the previous commit.

10 years agoentry: Use a permanent css node for progress
Matthias Clasen [Fri, 23 Oct 2015 20:11:08 +0000 (16:11 -0400)]
entry: Use a permanent css node for progress

Create a css node with name progressbar when we start showing progress
in the entry. The node gets the style class .pulse added when we
do pulse mode.

10 years agoAdwaita: Update for entry icon changes
Matthias Clasen [Fri, 23 Oct 2015 19:41:05 +0000 (15:41 -0400)]
Adwaita: Update for entry icon changes

10 years agoentry: Use css nodes for icons
Matthias Clasen [Fri, 23 Oct 2015 19:39:29 +0000 (15:39 -0400)]
entry: Use css nodes for icons

Create css nodes for icons in entries, with name image, and use
gtk_style_context_save_to_node() for them. We still set the
style classes .left and .right on them.

10 years agoHighContrast: Update entry styling
Matthias Clasen [Fri, 23 Oct 2015 18:53:06 +0000 (14:53 -0400)]
HighContrast: Update entry styling

Use the new element name instead of the style class.

10 years agoAdwaita: Update entry styling
Matthias Clasen [Fri, 23 Oct 2015 18:52:27 +0000 (14:52 -0400)]
Adwaita: Update entry styling

Use the new element name instead of the style class.
There is some minor fallout for vertical spin buttons that
will need a second look.

10 years agoentry: Use the element name entry
Matthias Clasen [Fri, 23 Oct 2015 18:51:35 +0000 (14:51 -0400)]
entry: Use the element name entry

Set the element name on the css node and drop the .entry class.

10 years agoAdwaita: fix switch styling
Lapo Calamandrei [Fri, 23 Oct 2015 15:12:01 +0000 (17:12 +0200)]
Adwaita: fix switch styling

looks like switch stare are not passed to the slider anymore so
rewrite selectors accordingly.

10 years agoAdwaita: generalize .has-open-popup
Lapo Calamandrei [Fri, 23 Oct 2015 14:58:17 +0000 (16:58 +0200)]
Adwaita: generalize .has-open-popup

so it works for any list-row istead of just the ones in a sidebar.

10 years agoshortcut: Improve formatting of ranges
Matthias Clasen [Fri, 23 Oct 2015 11:46:31 +0000 (07:46 -0400)]
shortcut: Improve formatting of ranges

Use a centered ellipsis, to make it look nicer.

10 years agoHighContrast: Update image styling
Matthias Clasen [Fri, 23 Oct 2015 04:05:46 +0000 (00:05 -0400)]
HighContrast: Update image styling

Use the new element name instead of the type name.

10 years agoAdwaita: Update image styling
Matthias Clasen [Fri, 23 Oct 2015 04:05:18 +0000 (00:05 -0400)]
Adwaita: Update image styling

Use the new element name instead of the type name.

10 years agoimage: Use the element name image
Matthias Clasen [Fri, 23 Oct 2015 04:04:47 +0000 (00:04 -0400)]
image: Use the element name image

Set hte element name on the CSS node.

10 years agoHighContrast: Update label styling
Matthias Clasen [Fri, 23 Oct 2015 03:26:53 +0000 (23:26 -0400)]
HighContrast: Update label styling

Use the new element name instead of the style class.

10 years agoAdwaita: Update label styling
Matthias Clasen [Fri, 23 Oct 2015 03:25:42 +0000 (23:25 -0400)]
Adwaita: Update label styling

Use the new element name instead of the style class.

10 years agolabel: Use the element name label
Matthias Clasen [Fri, 23 Oct 2015 03:18:30 +0000 (23:18 -0400)]
label: Use the element name label

Set the element name on the CSS node, and drop the .label style
class.

10 years agoswitch: Document css names a bit
Matthias Clasen [Fri, 23 Oct 2015 03:07:54 +0000 (23:07 -0400)]
switch: Document css names a bit

This is still provisional. Better gtk-doc support will be needed
to do better here.

10 years agoMSVC release builds: Ensure that /LTCG is used
Chun-wei Fan [Fri, 23 Oct 2015 02:33:41 +0000 (10:33 +0800)]
MSVC release builds: Ensure that /LTCG is used

MSVC 2015 changed its default link-time code generation setting to
/LTCG:incremental, which causes problems if /opt:noref is to be used,
meaning that some code will be optimized out by the linker.

Avoid this situtation here by enforcing the use of /LTCG for MSVC 2010+
builds.

10 years agoHighContrast: Update switch styling
Matthias Clasen [Fri, 23 Oct 2015 01:44:03 +0000 (21:44 -0400)]
HighContrast: Update switch styling

Use the new element names instead of the type name and style
classes, just like we did for Adwaita in the previous commit.

10 years agoAdwaita: Update switch styling
Matthias Clasen [Fri, 23 Oct 2015 01:42:20 +0000 (21:42 -0400)]
Adwaita: Update switch styling

Use the new element names instead of the type name and style
classes.

Note that there is one problem with moving away from type names
here: it turns out that style properties only work if the selector
uses the type name.

10 years agoswitch: Convert to element names
Matthias Clasen [Fri, 23 Oct 2015 01:40:31 +0000 (21:40 -0400)]
switch: Convert to element names

Use the element names switch and slider for the two css nodes,
and drop the .trough and .slider classes.

10 years agowidget: Always set the type on css nodes
Matthias Clasen [Fri, 23 Oct 2015 01:00:12 +0000 (21:00 -0400)]
widget: Always set the type on css nodes

See the previous commit for why this is necessary.

Also make gtk_widget_class_set_css_name work by looking at
the correct class for the name.

Note for future reference: GTK_WIDGET_GET_CLASS() does not
work in the instance init function.

10 years agocss node declaration: Allow both name and type to be set
Matthias Clasen [Fri, 23 Oct 2015 00:58:52 +0000 (20:58 -0400)]
css node declaration: Allow both name and type to be set

The widget path machinery assumes that we always have types,
and without this change, it will start spewing warnings when
we start to introduce node names.

10 years agoinspector: Show names for css nodes
Matthias Clasen [Fri, 23 Oct 2015 00:58:08 +0000 (20:58 -0400)]
inspector: Show names for css nodes

Currently, we don't have any css nodes with names, but we will soon.

10 years agoAdd since tags to new api
Matthias Clasen [Thu, 22 Oct 2015 23:27:13 +0000 (19:27 -0400)]
Add since tags to new api

gtk_widget_class_set/get_css_name were missing it.

10 years agoGtkApplicationWindow: Add missing annotations
Timm Bäder [Thu, 22 Oct 2015 17:31:36 +0000 (19:31 +0200)]
GtkApplicationWindow: Add missing annotations

10 years agogtk-demo: Add a range example to the shortcuts demo
Matthias Clasen [Thu, 22 Oct 2015 18:32:08 +0000 (14:32 -0400)]
gtk-demo: Add a range example to the shortcuts demo

This shows off the new range display capability that I just added.

10 years agoshortcuts: Support ranges in the display of shortcuts
Matthias Clasen [Thu, 22 Oct 2015 18:31:06 +0000 (14:31 -0400)]
shortcuts: Support ranges in the display of shortcuts

Repeating Alt-1 to Alt-9 as individual shortcuts looks really boring,
so allow compressing such ranges by specifying <Alt>1...9.

10 years agonotebook: On drag window hide, fix css nodes
Benjamin Otte [Thu, 22 Oct 2015 18:29:10 +0000 (20:29 +0200)]
notebook: On drag window hide, fix css nodes

10 years agoswitch: Use the right state when querying padding
Benjamin Otte [Thu, 22 Oct 2015 16:42:56 +0000 (18:42 +0200)]
switch: Use the right state when querying padding

We were using the state of the widget node, not the state of the slider
node.

This caused layout loops due to invalidations.

10 years agowin32: Fix introspection syntax
Matthias Clasen [Thu, 22 Oct 2015 15:50:49 +0000 (11:50 -0400)]
win32: Fix introspection syntax

10 years agotestgtk/Alpha Window: fix the drawn area when we are drawing decorations
Owen W. Taylor [Tue, 20 Oct 2015 20:45:52 +0000 (16:45 -0400)]
testgtk/Alpha Window: fix the drawn area when we are drawing decorations

A GtkWindow's allocation includes the titlebar, borders, and shadows; we
only want to draw our custom alpha content over the child allocation of
the GtkWindow.

https://bugzilla.gnome.org/show_bug.cgi?id=756886

10 years agoGtkWindow: draw the frame and shadow even for app-paintable windows
Owen W. Taylor [Tue, 20 Oct 2015 20:43:06 +0000 (16:43 -0400)]
GtkWindow: draw the frame and shadow even for app-paintable windows

If a window is decorated, we need to draw the frame and shadow, even if
it is app-paintable - it's just nonsense to have a frame that we handle
events on, but expect the app to paint it. (We paint the titlebar in
any case.) If a client wants to handle all painting, it should use an
undecorated window.

https://bugzilla.gnome.org/show_bug.cgi?id=756886